import { Base } from "./base";

export class Baidu extends Base {
  /**
   *
   * @param url
   * @returns {Promise<void>}
   */
  // eslint-disable-next-line camelcase
  async urls(url) {
    const { data = {} } = await this.$http("post", "/api/baidu/push/urls", {
      url
    });
    return data;
  }

  // eslint-disable-next-line camelcase
  async update(url) {
    const { data = {} } = await this.$http("post", "/api/baidu/push/update", {
      url
    });
    return data;
  }

  // eslint-disable-next-line camelcase
  async del(url) {
    const { data = {} } = await this.$http("post", "/api/baidu/push/del", {
      url
    });
    return data;
  }
}
